/*
 * Created on 17-ene-2005
 *
 * TODO To change the template for this generated file go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
package hotel.ejb;

//import hotel.interfaces.ClientLocal;

import java.rmi.RemoteException;

import javax.ejb.EJBException;
import javax.ejb.EntityBean;
import javax.ejb.EntityContext;
import javax.ejb.RemoveException;

/**
 * @ejb.bean name="Reserva"
 *           display-name="Name for Reserva"
 *           description="Description for Reserva"
 *           jndi-name="ejb/Reserva"
 *           type="CMP"
 *           cmp-version="2.x"
 *           view-type="local"
 * 
 * @ejb.persistence table-name="Reserva"
 *   
 * @ejb.value-object match="*" 
 *                   name="Reserva"
 * 
 * @jboss.persistence create-table="true"
 *                    remove_table="false"
 * 
 * @ejb.util generate="physical"
 * 
 * @ejb.finder signature="java.util.Collection findAll()" result-type-mapping="Local"
 */
public abstract class ReservaBean implements EntityBean {

	/**
	 * 
	 */
	public ReservaBean() {
		super();
		// TODO Auto-generated constructor stub
	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#ejbActivate()
	 */
	public void ejbActivate() throws EJBException, RemoteException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#ejbLoad()
	 */
	public void ejbLoad() throws EJBException, RemoteException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#ejbPassivate()
	 */
	public void ejbPassivate() throws EJBException, RemoteException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#ejbRemove()
	 */
	public void ejbRemove()
		throws RemoveException,
		EJBException,
		RemoteException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#ejbStore()
	 */
	public void ejbStore() throws EJBException, RemoteException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#setEntityContext(javax.ejb.EntityContext)
	 */
	public void setEntityContext(EntityContext ctx)
		throws EJBException,
		RemoteException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see javax.ejb.EntityBean#unsetEntityContext()
	 */
	public void unsetEntityContext() throws EJBException, RemoteException {
		// TODO Auto-generated method stub

	}

	/**
	 * Getter for CMP Field ID
	 *
	 * @ejb.pk-field
	 * @ejb.persistent-field
	 * @ejb.interface-method   view-type="both"
	 */
	public abstract java.lang.Integer getID();

	/**
	 * Setter for CMP Field ID
	 *
	 * @ejb.interface-method   view-type="both"
	 */
	public abstract void setID(java.lang.Integer value);

	/**
	 * Getter for CMP Field DesdeData
	 *
	 * 
	 * @ejb.persistent-field
	 * @ejb.interface-method   view-type="both"
	 */
	public abstract java.util.Date getDesdeData();

	/**
	 * Setter for CMP Field DesdeData
	 *
	 * @ejb.interface-method   view-type="both"
	 */
	public abstract void setDesdeData(java.util.Date value);

	/**
	 * Getter for CMP Field FinsData
	 *
	 * 
	 * @ejb.persistent-field
	 * @ejb.interface-method   view-type="both"
	 */
	public abstract java.util.Date getFinsData();

	/**
	 * Setter for CMP Field FinsData
	 *
	 * @ejb.interface-method   view-type="both"
	 */
	public abstract void setFinsData(java.util.Date value);

	/**
	 * Create method
	 * @ejb.create-method  view-type = "both"
	 */
	public hotel.interfaces.ReservaPK ejbCreate(
		hotel.interfaces.ReservaValue value) throws javax.ejb.CreateException {
		// TODO Auto-generated method stub
		this.setID(value.getID());
		this.setDesdeData(value.getDesdeData());
		this.setFinsData(value.getFinsData());
		return null;
	}
	/**
	 * Post Create method
	 */
	public void ejbPostCreate(hotel.interfaces.ReservaValue value)
		throws javax.ejb.CreateException {
		// TODO Auto-generated method stub
	}
	
	/**
	* @ejb.interface-method view-type="local"
	* 
	* @ejb.relation           name = "ReservaClient"
	*                         role-name = "reserva-te-client"
	* 
	* @jboss.relation         related-pk-field = "DNI"
	*                         fk-column = "DNI_fk"
	*/
	public abstract hotel.interfaces.ClientLocal getClient();

	/**
	* @ejb.interface-method
	*      view-type="local"
	*/
	public abstract void setClient(hotel.interfaces.ClientLocal value);
	
	/**
	* @ejb.interface-method view-type="local"
	* 
	* @ejb.relation           name = "ReservaHabitacio"
	*                         role-name = "reserva-te-habitacions"
	* 						  target-multiple="yes"
	* 
	* @jboss.relation-mapping
    *      style="relation-table" 
    * 
    * @jboss.relation-table
    *      table-name="ReservaHabitacions"
    *      create-table="true"
    *      remove-table="false"
    * 
    * @jboss.relation
    *      related-pk-field="ID"
    *      fk-column="habitacio_id_fk"
    *      fk-constraint="false"
    * 
	*/
	public abstract java.util.Collection getHabitacions();

	/**
	* @ejb.interface-method
	*      view-type="local"
	*/
	public abstract void setHabitacions(java.util.Collection value);


}